home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
64'er
/
64ER_CD.iso
/
89xx
/
8902a.d64
/
sub dir 1.1
(
.txt
)
< prev
Wrap
Commodore BASIC
|
1995-03-30
|
5KB
|
258 lines
100 REM ******************
110 REM * *
120 REM * SUB DIR SYSTEM *
130 REM * *
140 REM ******************
150 REM
160 REM (C) 1988 BY
170 REM DIRK JANSEN
180 REM
190 REM VER 1.1 - 21.07.88
200 REM ==================
210 :
220 PRINT CHR$(147)
230 PRINT TAB(13);"SUB DIR SYSTEM"
240 PRINT
250 PRINT TAB(13);"V1.1 21.07.88"
260 PRINT
270 PRINT TAB(8);"(C) 1988 BY DIRK JANSEN"
280 PRINT
290 PRINT"========================================"
300 GOSUB 4000:REM * GERAETE NUMMERN ABFRAGEN
340 PRINT CHR$(147)
350 PRINT"***** SUB DIR SYSTEM V 1.1 *****"
360 PRINT
370 PRINT"GERAET:";U,"LAUFWERK: ";D$
380 PRINT:PRINT
390 PRINT" 1 - SUB DIR SYSTEM ANLEGEN"
400 PRINT
410 PRINT" 2 - SUB DIR ANLEGEN"
420 PRINT
430 PRINT" 3 - DISK BEFEHL"
440 PRINT
450 PRINT" 4 - INHALTSVERZEICHNIS"
460 PRINT
470 PRINT" 5 - GERAETE NUMMEN AENDERN"
480 PRINT
490 PRINT" 0 - PROGRAMM ENDE"
500 PRINT:PRINT
510 INPUT"IHRE WAHL";O
520 ON O+1 GOSUB 1000,10000,20000,2000,3000,4000
530 GOTO 340
970 :
980 REM *** ENDE ***
990 :
1000 SYS 64738
1970 :
1980 REM *** DISK BEFEHL ***
1990 :
2000 PRINT
2010 POKE 198,3
2020 POKE 631,34
2030 POKE 632,20
2040 POKE 633,34
2050 A$=""
2060 INPUT"BEFEHL";A$
2070 OPEN 15,U,15
2080 IF A$="" THEN 2200
2090 PRINT#15,A$
2200 PRINT
2210 PRINT"STATUS: ";
2220 GET#15,E$:IF E$<>CHR$(13) THEN PRINT E$;:GOTO 2220
2230 CLOSE 15
2240 PRINT:PRINT:PRINT"- TASTE DRUECKEN -"
2250 GET A$:IF A$="" THEN 2250
2260 RETURN
2970 :
2980 REM *** INHALTSVERZEICHNIS ***
2990 :
3000 PRINT
3010 OPEN 1,U,0,"$"+D$
3020 POKE 781,1
3040 GET#1,A$,A$
3050 GET#1,A$,A$:IF ST = 64 THEN 3110
3060 : GET#1,A$,B$:PRINT CHR$(157);ASC(A$+CHR$(0))+256*ASC(B$+CHR$(0));
3070 : GET#1,A$:PRINT A$;:IF A$<>"" THEN 3070
3080 : PRINT
3090 GOTO 3050
3110 CLOSE 1
3120 PRINT:PRINT:PRINT"- TASTE DRUECKEN -"
3130 GET A$:IF A$="" THEN 3130
3140 RETURN
3970 :
3980 REM *** GERAETE NUMMERN AENDERN ***
3990 :
4000 PRINT
4010 INPUT"GERAETE NUMMER? 8[157][157][157]";U
4020 IF U<8 OR U>15 THEN 4010
4030 INPUT"LAUFWERK ? 0[157][157][157]";D$
4040 IF D$<>"0" AND D$<>"1" THEN 4040
4050 RETURN
9970 :
9980 REM *** SYSTEM ANLEGEN ***
9990 :
10000 OPEN 15,U,15,"I"+D$
10010 INPUT#15,E1,E2$,E3,E4
10020 IF E1=0 THEN 10100
10030 PRINT
10040 PRINT"*** DISK: ";E1;E2$;E3;E4;"***"
10050 PRINT
10060 RETURN
10100 OPEN 2,U,2,"#"
10110 PRINT#15,"U1 2 ";D$;" 18 1"
10112 FOR I=2 TO 226 STEP 32
10120 : PRINT#15,"B-P 2";I
10130 : GET#2,T$
10150 : IF T$<>"" THEN 10170
10160 NEXT I
10162 PRINT#15,"B-P 2 0"
10164 GET#2,T$
10166 IF T$="" THEN 10220
10170 : PRINT
10180 : PRINT"*** DISK IST NICHT LEER ***"
10190 : PRINT
10200 : INPUT"DISK LOESCHEN(J/N)? N[157][157][157]";A$
10210 : IF A$="N" THEN CLOSE 2:CLOSE 15:RETURN
10220 : PRINT:PRINT"IMPRESSUM SCHREIBEN"
10222 PRINT#15,"B-P 2 00"
10230 PRINT#2,CHR$(0);CHR$(255);
10240 FOR I=0 TO 7
10242 : PRINT#15,"B-P 2";I*32+2
10250 : PRINT#2,CHR$(195);CHR$(18);CHR$(0);
10260 : READ A$
10270 : PRINT#2,LEFT$(A$+"[160][160][160][160][160][160][160][160][160][160][160][160][160][160][160]",16);
10280 : PRINT#2,CHR$(0);CHR$(0);CHR$(0);
10290 : PRINT#2,"DIRK";
10300 : PRINT#2,CHR$(0);CHR$(0);
10310 : PRINT#2,CHR$(0);CHR$(0);
10320 NEXT I
10330 PRINT#15,"U2 2 ";D$;" 18 01"
10340 PRINT:PRINT"ROOT DIR ANLEGEN"
10350 CLOSE 2
10360 CLOSE 15
10370 N$="======ROOT======":REM -NAME UEBERGEBEN
10380 GOSUB 30000:REM - DIR ANLEGEN
10470 OPEN 15,U,15
10480 PRINT:PRINT"INIT DISK"
10490 PRINT#15,"I";D$
10500 PRINT:PRINT"VALIDATE DISK"
10510 PRINT#15,"V";D$
10520 CLOSE 15
10530 RETURN
10662 PRINT#15,"B-P 2 0"
10664 GET#2,T$
10666 IF T$<>"" THEN 10180
12000 DATA " SUB DIR SYSTEM "
12010 DATA "(W) '88 D.JANSEN"
12020 DATA " "
12030 DATA "USE DISK COMMAND"
12040 DATA " &XXXXXX TO "
12050 DATA " CHANGE DIR "
12060 DATA " "
12070 DATA " DON'T VALIDATE "
19970 :
19980 REM *** DIR ANLEGEN ***
19990 :
20000 PRINT
20010 N$="":INPUT"DIR NAME (MAX 15 ZEICEN)";N$
20020 IF LEN(N$)>15 OR LEN(N$)<1 THEN 20010
20030 N1$=N$
20040 IF LEN(N$)<16 THEN N$="="+N$+"=":GOTO 20040
20050 N$=LEFT$(N$,16)
21000 PRINT:PRINT"DIR ANLEGEN"
21010 GOSUB 30000:REM - DIR ANLEGEN
21900 RESTORE
21910 FOR I=0 TO 7
21920 : READ A$
21930 NEXT I
22000 PRINT:PRINT"UMSCHALT BEFEHL ANLEGEN T:";T;" S:";S
22010 OPEN 2,U,2,"&"+N1$+",U,W"
22020 PRINT#2,CHR$(0);CHR$(5);:REM - STARTADRESSE
22030 PRINT#2,CHR$(35);:REM - ANZAHL BYTES
22040 P=0
22050 FOR I=1 TO 35
22060 : READ A
22070 : IF A=-1 THEN A=T
22080 : IF A=-2 THEN A=S
22090 : P=P+A:IF P>255 THEN P=P-255
22100 : PRINT#2,CHR$(A);
22110 NEXT I
22120 P=P+5+35
22130 P=P-(255*INT(P/256))
22140 PRINT#2,CHR$(P);
22150 CLOSE 2
23000 PRINT:PRINT"UMSCHALTEN"
23010 OPEN 15,U,15
23020 OPEN 2,U,2,"#"
23030 PRINT#15,"U1 2 ";D$;" 18 01"
23040 PRINT#15,"B-P 2 0"
23050 GET#2,T$,S$
23060 T=ASC(T$+CHR$(0))
23070 S=ASC(S$+CHR$(0))
23080 CLOSE 2
23090 PRINT#15,"&"+N1$
23100 CLOSE 15
23900 RESTORE
23910 FOR I=0 TO 7
23920 : READ A$
23930 NEXT I
24000 PRINT:PRINT"RUECKSCHALT BEFEHL ANLEGEN T:";T;" S:";S
24010 OPEN 2,U,2,"&BACK,U,W"
24020 PRINT#2,CHR$(0);CHR$(5);:REM - STARTADRESSE
24030 PRINT#2,CHR$(35);:REM - ANZAHL BYTES
24040 P=0
24050 FOR I=1 TO 35
24060 : READ A
24070 : IF A=-1 THEN A=T
24080 : IF A=-2 THEN A=S
24090 : P=P+A:IF P>255 THEN P=P-255
24100 : PRINT#2,CHR$(A);
24110 NEXT I
24120 P=P+5+35
24130 P=P-(255*INT(P/256))
24140 PRINT#2,CHR$(P);
24150 CLOSE 2
25000 PRINT:PRINT"RUECKSCHALTEN"
25010 OPEN 15,U,15
25020 PRINT#15,"&BACK"
25030 CLOSE 15
25040 RETURN
29970 :
29980 REM *** DIR ANLEGEN ***
29990 :
30000 OPEN 15,U,15
30010 OPEN 2,U,2,"#"
30020 PRINT#15,"U1 2 ";D$;" 18 01"
30030 PRINT#15,"B-P 2 0"
30040 GET#2,T$
30050 T1=ASC(T$+CHR$(0))
30070 PRINT#15,"B-A ";D$;" 18 00"
30080 INPUT#15,A,A$,T,S
30090 PRINT#15,"B-A ";D$;T;S
30100 PRINT#15,"B-P 2 00"
30110 PRINT#2,CHR$(0);CHR$(255);
30120 PRINT#2,CHR$(195);CHR$(18);CHR$(0);
30130 PRINT#2,LEFT$(N$+"[160][160][160][160][160][160][160][160][160][160][160][160][160][160][160][160]",16);
30140 PRINT#2,CHR$(0);CHR$(0);CHR$(0);
30150 PRINT#2,"DIR ";
30160 PRINT#2,CHR$(0);CHR$(0);
30170 PRINT#2,CHR$(0);CHR$(0);
30180 PRINT#2,CHR$(0);CHR$(0);
30260 FOR I=34 TO 253
30270 : PRINT#2,CHR$(0);
30280 NEXT I
30300 PRINT#15,"U2 2 ";D$;T;S
30310 IF T1=18 THEN 30500
30320 : PRINT#15,"U1 2 ";D$;" 18 01"
30330 : PRINT#15,"B-P 2 0"
30340 : PRINT#2,CHR$(T);CHR$(S);
30350 : PRINT#15,"U2 2 ";D$;" 18 01"
30500 CLOSE 15
30510 CLOSE 2
30520 RETURN
39970 :
39980 REM *** DATEN FUER & FILE ***
39990 :
40000 DATA169,18,133,8,169,1,133,9,169,128,133,1,165,1,48,252,169,-1,141,0,4
40010 DATA169,-2,141,1,4,169,144,133,1,165,1,48,252,96